package pt.nmfa.peste.session;

import pt.nmfa.peste.entity.*;
import org.jboss.seam.annotations.Name;
import org.jboss.seam.framework.EntityQuery;
import java.util.Arrays;

@Name("feedTvList")
public class FeedTvList extends EntityQuery<FeedTv> {

	private static final String EJBQL = "select feedTv from FeedTv feedTv";

	private static final String[] RESTRICTIONS = { "lower(feedTv.tvName) like lower(concat(#{feedTvList.feedTv.tvName},'%'))", };

	private FeedTv feedTv = new FeedTv();

	public FeedTvList() {
		setEjbql(EJBQL);
		setRestrictionExpressionStrings(Arrays.asList(RESTRICTIONS));
		setMaxResults(25);
	}

	public FeedTv getFeedTv() {
		return feedTv;
	}
}
